<?php

use Illuminate\Support\Facades\Route;

use App\Http\Controllers\BusinessController;
use App\Http\Controllers\ShopController;

/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/

Route::get('/', function () {
    return view('welcome');
});

/* 客户资料 */
Route::get('/business', [BusinessController::class, 'index'])->name('business');  // 页面路由
Route::post('/business/gender', [BusinessController::class, 'gender']);
Route::post('/business/auth', [BusinessController::class, 'auth']);
Route::post('/business/region', [BusinessController::class, 'region']);   // 处理提交数据的路由
Route::post('/business/source', [BusinessController::class, 'source']);

/* 食品商城 */
Route::get('/shop', [ShopController::class, 'index'])->name('shop');
// Route::match(['get', 'post'], [BusinessController::class, 'index']);
